package com.scott.providerc;

import com.scott.providerc.service.SayBayService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.boot.SpringApplication;
import org.springframework.boot.autoconfigure.SpringBootApplication;
import org.springframework.cloud.netflix.eureka.server.EnableEurekaServer;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RestController;

@RestController("/")
@EnableEurekaServer
@SpringBootApplication
public class ProviderCApplication {
    @Autowired
    SayBayService sayBayService;

    public static void main(String[] args) {
        SpringApplication.run(ProviderCApplication.class, args);
    }


    @GetMapping("say")
    public String sayHello() {
        return sayBayService.bay();
    }

}
